package com.muk.webframework.framework.util;

import java.util.Iterator;
import java.util.Map;

public class MapUtil {

	public static String ToStringMap(Map m) {
		String ret = "[";
		Iterator it = m.entrySet().iterator();
		while (it.hasNext()) {
			Map.Entry pairs = (Map.Entry) it.next();
			ret += String.format("%s : %s, ", pairs.getKey(), ((String[])pairs.getValue())[0]);
		}
		ret = (ret.length()>2)?ret.substring(0, ret.length()-2)+"]":"";
		return ret;
	}

}
